/**
 * Created by commy on 2015/5/1.
 */
var mongoose = require('mongoose'),
    config = require('../config');

mongoose.connect(config.db_url,function(err){
    if(err){
        console.error('connect to %s error: ', config.db, err.message);
        process.exit(1);
    }
});


require('./user');
require('./category');
require('./clothes');
exports.User =  mongoose.model('User');
exports.Category =  mongoose.model('Category');
exports.Clothes =  mongoose.model('Clothes');